<?php
/* Template Name: Faculty Page */
?>

<?php
/**
 * Layout giảng viên
 */

get_header(); get_template_part('block', 'header-faculty');
$list_faculty = is_array(get_field('faculty')) ? get_field('faculty') : array();
?>
    <section class="fix">
        <div class="box-list-faculty">
            <?php foreach($list_faculty as $faculty):?>
            <article class="item">
                <div class="thumb">
                    <a href="<?php echo (trim($faculty['detail_trainers']) != '') ? $faculty['detail_trainers'] : '#'; ?>"><img src="<?php echo $faculty['image']['url'];?>" width="220" height="220" alt="<?php echo $faculty['fullname'];?>" title="<?php echo $faculty['fullname'];?>"/></a>
                </div>
                <h3><a href="<?php echo (trim($faculty['detail_trainers']) != '') ? $faculty['detail_trainers'] : '#'; ?>"><?php echo $faculty['fullname'];?></a></h3>
                <p><?php echo $faculty['detail'];?></p>
            </article>
            <?php endforeach;?>
        </div>
    </section>
<?php get_footer(); ?>